<template>
	<view>
		<view style="text-align: center;padding: 20px 0 10px 0;">
					<image :src="data.icon" style="width: 60px;height: 60px;border-radius: 15px;"></image>
					<h3 style="margin-top: 5px;">{{data.title}}</h3>
					<p style="font-size: 13px;color: #989898;margin-top: 5px;">{{data.size}} | {{data.down}}次下载 | <span style="color: red;" @click="report(data._id,data.title)">举报</span></p>
				</view>
				<view v-if="data.content!=null&&data.content!=''" style="background-color: #fff6e4;padding: 5px;color: #7b7458;margin: 10px 20px;border-radius: 7px;font-size: 14px;text-align: left;">
					<rich-text selectable :nodes="data.content"></rich-text>
				</view>
				<scroll-view class="scroll-view_H" scroll-x="true">
					<image @click="openImg(data.image,index)" v-for="(item,index) in data.image" style="width: 150px;border-radius: 5px;margin: 10px 5px;"
						mode="widthFix" :src="item">
					</image>
				</scroll-view>
			<view style="margin-top: 10px;background-color: white;padding: 10px;">
				<u-cell-group>
						<u-cell icon="tags-fill" title="应用包名" :value="data.package"></u-cell>
						<u-cell icon="level" title="应用版本" :value="data.version"></u-cell>
						<u-cell icon="clock-fill" title="更新时间" :value="$u.timeFrom(new Date(data.time).getTime(),false)"></u-cell>
					</u-cell-group>
			</view>
			<view style="height: 100px;">
				
			</view>
			<view style="width: 100%;background-color: white;position: fixed;bottom: 0px;">
				<view style="height: 1px;background-color: #f1f1f1;"/>
				<button style="margin: 10px 30px;border-radius: 50px;" type="primary" @click="down(data._id)">下载</button>
		<websitenav></websitenav>
		</view>
	</view>
</template>

<script>
		import ase from '@/common/ar-aes/ar-aes.js'
	export default {
		props: {
			data: {
				type: Object,
				default (data) {
					return {}
				}
			}
		},
		name: "apk_jingdian",
		methods:{
			report(id,title){
				uni.navigateTo({
					url: '../feedback/feedback?id='+id+'&type=file'
				});
			},
		down(id){
						this.$emit("down",{id:id})
					}
		}
	}
</script>

<style lang="less">
page{
	background-color: white;
}
.scroll-view_H {
		white-space: nowrap;
		width: 100%;
	}
</style>
